preserve
	clustermat singlelinkage distmat, clear force
	
	return list
	ereturn list
	
	local ordering=""
		forval i=1/8 {
			local add_to_ordering=_clus_1_ord[`i']
			local ordering="`ordering' `add_to_ordering'"
		}
	di "ordering=`ordering'"	
restore
*need to move the labels to match this ordering


local labellist=""
forval k=1/8 {
	
		local order_num= "`: word `k' of `ordering''"
		
		local var_to_add=" `: word `order_num' of `wordlist''"
		
		local label_to_add=" `: var label `var_to_add''"

		local labellist="`labellist' `k' qq `label_to_add' qq "

}

di "labellist=`labellist'"


local labellist=subinstr("`labellist'","qq",char(34),.)

		
ttdendro, xlabel(`labellist') title("`title'")